import table from '@/components/dt/table/render.js'
import Opt from '@/components/dt/info/Opt.js'
let _this = null
class Column extends Opt {
  constructor(vm) {
    super()
    _this = vm
    this.build()
  }

  build() {
    this.createAll()
    this.opts.push(...this.all)
  }

  createAll() {
    this.all = [
      {
        field: 'orgName',
        title: '业务组织',
        minWidth: 80
      },
      {
        field: 'buildingName',
        title: '案场名称',
        minWidth: 150
      },
      {
        field: 'buildingStatusName',
        title: '案场状态',
        minWidth: 150
      },
      {
        field: 'customerProtectStatusName',
        title: '客户到访保护期',
        minWidth: 150,
        header: {
          filter: {
            title: '客户到访保护期',
            key: 'customerProtectStatus',
            placeholder: '请选择',
            select: {
              options: [
                {
                  key: 1,
                  value: '开'
                },
                {
                  key: 0,
                  value: '关'
                }
              ]
            }
          }
        }
      },
      {
        field: 'buildingProtectStatusName',
        title: '案场保护期',
        minWidth: 150,
        header: {
          filter: {
            title: '案场保护期',
            key: 'buildingProtectStatus',
            placeholder: '请选择',
            select: {
              options: [
                {
                  key: 1,
                  value: '开'
                },
                {
                  key: 0,
                  value: '关'
                }
              ]
            }
          }
        }
      }
    ]
  }
}

export default Column
